<template>
  <el-carousel trigger="click"
               height="750px">
    <el-carousel-item v-for="item in newProduct">
      <a :href="item.Url"><img :src="item.Image" class="new-img"></img></a>
    </el-carousel-item>
  </el-carousel>
</template> 
<style>
.el-carousel__item h3 {
  color: #475669;
  font-size: 0px;
  opacity: 0.75;
  line-height: 150px;
  margin: 0;
}
.new-img{
  width: 100%;
  height: 100%;
}
</style>
<script>

export default {
  data: function () {
    return {
      newProduct: []
    }
  },
  created: function () {
    var _this = this;
    $.ajax({
      type: "Patch",
      url: "/api/Goods/GetNewProduct",
      dataType: "json",contentType: "application/json",
      success: function (data) {
          _this.newProduct=data;    
      },
      error: function (msg) {
        alert(msg);
      }
    });

  }
}
</script>
 